Returns an integer that represents the seconds of the serial time number that is generated by the TimeSerial or the TimeValue function.
TimeSerial ないし TimeValue 関数による時刻データのシリアル変換値を基に、該当時刻の秒を示す数値を返します。
Second (Number)
Second (Number)
Integer
整数
Number: Numeric expression that contains the serial time number that is used to calculate the number of seconds.
Number: 秒情報を得る時刻データのシリアル変換値を示す数値表式。
This function is the opposite of the TimeSerial function. It returns the seconds of a serial time value that is generated by the TimeSerial or TimeValue functions. For example, the expression:
この関数は、TimeSerial 関数と逆方向の機能を担っています。この場合の戻り値としては、時刻データを TimeSerial や TimeValue 関数で変換したシリアル値を基に、該当時刻の秒を示す整数値が返されます。こうした点は、下記のコードを実行してみると分かりやすいでしょう。
Print Second(TimeSerial(12,30,41))
Print Second(TimeSerial(12,30,41))
returns the value 41.
この場合の戻り値は 41 となります。
Sub ExampleSecond
Sub ExampleSecond
MsgBox "The exact second of the current time is "& Second( Now )
MsgBox "正確な現在時刻の秒は、 "& Second( Now )
End sub
End sub